<template>
    <div>
        <el-row>
            <el-col :span="4">
                <div>
                    <el-menu>
                        <el-submenu index="1">
                            <template slot="title">
                                <span >积分商品</span>
                            </template>
                            <el-menu-item index="1-1"  @click="myMove">积分商品</el-menu-item>
                        </el-submenu>
                        <el-submenu index="2">
                            <template slot="title">
                                <span>充值话费</span>
                            </template>
                            <el-menu-item index="1-1" @click="Recharge">话费充值</el-menu-item>
                        </el-submenu>
                        <el-submenu index="3">
                            <template slot="title">
                                <span>优惠券</span>
                            </template>
                            <el-menu-item index="1-1" @click="coupon">优惠券兑换</el-menu-item>
                            <el-menu-item index="1-2" @click="myCoupon">我的优惠券</el-menu-item>
                        </el-submenu>
                        <el-submenu index="4">
                            <template slot="title">
                                <span>秒杀</span>
                            </template>
                            <el-menu-item index="1-1" @click="newKill">新增秒杀(暂存)</el-menu-item>
                            <el-menu-item index="1-2" @click="kill">秒杀</el-menu-item>
                        </el-submenu>
                    </el-menu>
                </div>
            </el-col>
            <el-col :span="20">
                <!-- 将路由视图放在这里 -->
                <router-view></router-view>
            </el-col>
        </el-row>
    </div>
</template>

<script>
export default {
    data(){
        return{

        }
    },
    methods:{
        myMove(){
            this.$router.push({path:'/jiFenList'})
        },
        Recharge(){
            this.$router.push({path:'/jiFenRecharge'})
        },
        coupon(){
            this.$router.push("/coupon");        
        },
        myCoupon(){
            this.$router.push("/myCoupon");        
        },
        newKill(){
            this.$router.push("/newKill");     
        },
        kill(){

        }
    },
    created(){

    }
}
</script>

<style>
.custom-submenu {
    margin-left: 30px;
}

.centered-text-button {
    text-align: center;
    /* 水平居中 */
    line-height: 10px;
    /* 垂直居中 */
}
</style>